package com.atguigu.gulimall.auth.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

/**
 * @Author: charls
 * @Description:TODO
 * @Date: 2023/05/13/ 18:24
 * @Version: 1.0
 */

@Configuration
public class GulimallWebConfig implements WebMvcConfigurer {

    @Override
    public void addViewControllers(ViewControllerRegistry registry) {

        /*@GetMapping("/login.html")
        public String loginPage(){
            return "login";
        }*/
        // registry.addViewController("/login.html").setViewName("login");

        /*@GetMapping("/reg.html")
        public String regPage(){
            return "reg";
        }*/
        registry.addViewController("/reg.html").setViewName("reg");
    }
}
